import os
import pandas as pd 
from multiprocessing import Pool


dir = "./13.tree_annotation_to_table"
files = os.listdir(dir)

def read_df(file_path, name):
    print(file_path)
    df = pd.read_excel(file_path, keep_default_na=False)
    return df 

tasks = []
for f in files:
    tasks.append((os.path.join(dir,f),""))
    
with Pool(250) as pool:
    dfs = pool.starmap(read_df, tasks)
    
df = pd.concat(dfs)
df.to_excel("16.merge_tble.xlsx", index=None)